using System;
using System.Collections.Generic;
using System.Text;
using it.mintlab.desktopnet.mintar;
using Newtonsoft.Json.Converters;
using System.Reflection;

namespace it.mintlab.desktopnet.restlib
{
    public class ModelConverter : CustomCreationConverter<Model>
    {

        public override Model Create(Type objectType)
        {
            ConstructorInfo constructor = objectType.GetConstructor(System.Type.EmptyTypes);
            return (Model)constructor.Invoke(null);
        }

    }
}
